package com.to3ks.service.base.config;


import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
import lombok.extern.slf4j.Slf4j;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.transaction.annotation.EnableTransactionManagement;

//@EnableTransactionManagement
@Configuration
@MapperScan({"com.to3ks.eduservice.mapper","com.to3ks.xlsservice.mapper","com.to3ks.excelservice.mapper"})
//@MapperScan("com.to3ks.excelservice.mapper")
@Slf4j
public class MybatisPlusConfig {

    /**
     * 分页插件
     */
    @Bean
    public PaginationInterceptor paginationInterceptor() {
        log.info("*********"+"分页插件PaginationInterceptor被单例加载********");
        return new PaginationInterceptor();
    }
}
